package cn.iocoder.yudao.module.of.enums;

import cn.hutool.core.util.ArrayUtil;
import cn.iocoder.yudao.framework.common.core.ArrayValuable;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Arrays;

@Getter
@AllArgsConstructor
public enum HandlerTypeEnum implements ArrayValuable<Integer> {

    MASTER_LEVEL(1, "主办"),
    SUB_LEVEL(2, "从办");

    public static final Integer[] ARRAYS = Arrays.stream(values()).map(HandlerTypeEnum::getCode).toArray(Integer[]::new);

    /**
     * 状态值
     */
    private final Integer code;
    /**
     * 状态名
     */
    private final String name;

    @Override
    public Integer[] array() {
        return ARRAYS;
    }
}
